
public class CH2Demo {

    /*    public static void  main(String arg[]){}*/

    /*public static void main(String[] args) {
        *//* float boy []=new float[4]; *//*
 *//*       float boy [];
        boy=new float[5];
        boy[0]=0;
        boy[1]=1;
        boy[2]=2;
        boy[3]=3;
        boy[4]=4;*//*
        float boy[] = {0, 1f, 2f, 3f, 4f};
        float aa = 1.0f;
        double bb = 1.0f;
        *//*System.out.println()*//*
*//*
        System.out.println("boy[0]="+boy[0]);
        System.out.println("boy[1]="+boy[1]);
        System.out.println("boy[2]="+boy[2]);
        System.out.println("boy[3]="+boy[3]);
        System.out.println("boy[4]="+boy[4]);
*//*
 *//*       for(int i=0; i< 5; i++){
            System.out.println("boy["+i+"]="+boy[i]);
        }*//*
        for (int i = 0; i < boy.length; i++) {//for-i循环
            System.out.println("boy[" + i + "]=" + boy[i]);
        }

        for (float aa : boy) {//for-each循环
            System.out.println(aa);
        }

    }*/

/*    public static void main(String[] args) {
        String str1 = "abc";
        System.out.println(str1 =="abc");//输出true
        System.out.println(str1.equals("abc"));//输出true
        String str2 = new String("abc");
        System.out.println(str2 =="abc");//输出false
        System.out.println(str2.equals("abc"));//输出true
    }*/
/*
    public static void main(String[] args) {
        System.out.println("5/2="+5/2f);
    }
*/
    public static void main(String[] args) {
        int x=1,y=10;
        if( ((x=1)==0) || ((y=20)==20) )
        {
            System.out.println("现在y的值是:"+y);
        }
    }
}

